Integrand size = 23, antiderivative size = 195 \[ \int \frac {(d \csc (e+f x))^n}{3+b \sin (e+f x)} \, dx=\frac {b \operatorname {AppellF1}\left (\frac {1}{2},\frac {n}{2},1,\frac {3}{2},\cos ^2(e+f x),-\frac {b^2 \cos ^2(e+f x)}{9-b^2}\right ) \cos (e+f x) (d \csc (e+f x))^{1+n} \sin (e+f x) \sin ^2(e+f x)^{n/2}}{\left (9-b^2\right ) d f}-\frac {3 \operatorname {AppellF1}\left (\frac {1}{2},\frac {1+n}{2},1,\frac {3}{2},\cos ^2(e+f x),-\frac {b^2 \cos ^2(e+f x)}{9-b^2}\right ) \cos (e+f x) (d \csc (e+f x))^{1+n} \sin ^2(e+f x)^{\frac {1+n}{2}}}{\left (9-b^2\right ) d f} \]
b*AppellF1(1/2,1/2*n,1,3/2,cos(f*x+e)^2,-b^2*cos(f*x+e)^2/(a^2-b^2))*cos(f *x+e)*(d*csc(f*x+e))^(1+n)*sin(f*x+e)*(sin(f*x+e)^2)^(1/2*n)/(a^2-b^2)/d/f -a*AppellF1(1/2,1/2+1/2*n,1,3/2,cos(f*x+e)^2,-b^2*cos(f*x+e)^2/(a^2-b^2))* cos(f*x+e)*(d*csc(f*x+e))^(1+n)*(sin(f*x+e)^2)^(1/2+1/2*n)/(a^2-b^2)/d/f
Leaf count is larger than twice the leaf count of optimal. \(1581\) vs. \(2(195)=390\).
Time = 16.38 (sec) , antiderivative size = 1581, normalized size of antiderivative = 8.11 \[ \int \frac {(d \csc (e+f x))^n}{3+b \sin (e+f x)} \, dx =\text {Too large to display} \]
((d*Csc[e + f*x])^n*(Cot[e + f*x]*Sqrt[Sec[e + f*x]^2])^n*Tan[e + f*x]*(-3 *b*(-2 + n)*AppellF1[(1 - n)/2, -1/2*n, 1, (3 - n)/2, -Tan[e + f*x]^2, ((- 9 + b^2)*Tan[e + f*x]^2)/9] + (-1 + n)*((-9 + b^2)*AppellF1[1 - n/2, (-1 - n)/2, 1, 2 - n/2, -Tan[e + f*x]^2, ((-9 + b^2)*Tan[e + f*x]^2)/9] + 9*Hyp ergeometric2F1[1/2 - n/2, 1 - n/2, 2 - n/2, -Tan[e + f*x]^2])*Tan[e + f*x] ))/(9*b*f*(-2 + n)*(-1 + n)*(Sec[e + f*x]^2)^(n/2)*(3 + b*Sin[e + f*x])*(( (Sec[e + f*x]^2)^(1 - n/2)*(Cot[e + f*x]*Sqrt[Sec[e + f*x]^2])^n*(-3*b*(-2 + n)*AppellF1[(1 - n)/2, -1/2*n, 1, (3 - n)/2, -Tan[e + f*x]^2, ((-9 + b^ 2)*Tan[e + f*x]^2)/9] + (-1 + n)*((-9 + b^2)*AppellF1[1 - n/2, (-1 - n)/2, 1, 2 - n/2, -Tan[e + f*x]^2, ((-9 + b^2)*Tan[e + f*x]^2)/9] + 9*Hypergeom etric2F1[1/2 - n/2, 1 - n/2, 2 - n/2, -Tan[e + f*x]^2])*Tan[e + f*x]))/(9* b*(-2 + n)*(-1 + n)) + (n*(Cot[e + f*x]*Sqrt[Sec[e + f*x]^2])^(-1 + n)*(Sq rt[Sec[e + f*x]^2] - Csc[e + f*x]^2*Sqrt[Sec[e + f*x]^2])*Tan[e + f*x]*(-3 *b*(-2 + n)*AppellF1[(1 - n)/2, -1/2*n, 1, (3 - n)/2, -Tan[e + f*x]^2, ((- 9 + b^2)*Tan[e + f*x]^2)/9] + (-1 + n)*((-9 + b^2)*AppellF1[1 - n/2, (-1 - n)/2, 1, 2 - n/2, -Tan[e + f*x]^2, ((-9 + b^2)*Tan[e + f*x]^2)/9] + 9*Hyp ergeometric2F1[1/2 - n/2, 1 - n/2, 2 - n/2, -Tan[e + f*x]^2])*Tan[e + f*x] ))/(9*b*(-2 + n)*(-1 + n)*(Sec[e + f*x]^2)^(n/2)) - (n*(Cot[e + f*x]*Sqrt[ Sec[e + f*x]^2])^n*Tan[e + f*x]^2*(-3*b*(-2 + n)*AppellF1[(1 - n)/2, -1/2* n, 1, (3 - n)/2, -Tan[e + f*x]^2, ((-9 + b^2)*Tan[e + f*x]^2)/9] + (-1 ...
Time = 0.75 (sec) , antiderivative size = 216, normalized size of antiderivative = 1.11, number of steps used = 10, number of rules used = 9, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.391, Rules used = {3042, 3717, 3042, 4356, 3042, 3302, 3042, 3668, 333}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {(d \csc (e+f x))^n}{a+b \sin (e+f x)} \, dx\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \int \frac {(d \csc (e+f x))^n}{a+b \sin (e+f x)}dx\) |
\(\Big \downarrow \) 3717 |
\(\displaystyle \frac {\int \frac {(d \csc (e+f x))^{n+1}}{b+a \csc (e+f x)}dx}{d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\int \frac {(d \csc (e+f x))^{n+1}}{b+a \csc (e+f x)}dx}{d}\) |
\(\Big \downarrow \) 4356 |
\(\displaystyle \frac {\sin ^{n+1}(e+f x) (d \csc (e+f x))^{n+1} \int \frac {\sin ^{-n}(e+f x)}{a+b \sin (e+f x)}dx}{d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\sin ^{n+1}(e+f x) (d \csc (e+f x))^{n+1} \int \frac {\sin (e+f x)^{-n}}{a+b \sin (e+f x)}dx}{d}\) |
\(\Big \downarrow \) 3302 |
\(\displaystyle \frac {\sin ^{n+1}(e+f x) (d \csc (e+f x))^{n+1} \left (a \int \frac {\sin ^{-n}(e+f x)}{a^2-b^2 \sin ^2(e+f x)}dx-b \int \frac {\sin ^{1-n}(e+f x)}{a^2-b^2 \sin ^2(e+f x)}dx\right )}{d}\) |
\(\Big \downarrow \) 3042 |
\(\displaystyle \frac {\sin ^{n+1}(e+f x) (d \csc (e+f x))^{n+1} \left (a \int \frac {\sin (e+f x)^{-n}}{a^2-b^2 \sin (e+f x)^2}dx-b \int \frac {\sin (e+f x)^{1-n}}{a^2-b^2 \sin (e+f x)^2}dx\right )}{d}\) |
\(\Big \downarrow \) 3668 |
\(\displaystyle \frac {\sin ^{n+1}(e+f x) (d \csc (e+f x))^{n+1} \left (\frac {b \sin ^{-n}(e+f x) \sin ^2(e+f x)^{n/2} \int \frac {\left (1-\cos ^2(e+f x)\right )^{-n/2}}{a^2-b^2+b^2 \cos ^2(e+f x)}d\cos (e+f x)}{f}-\frac {a \sin ^{-n-1}(e+f x) \sin ^2(e+f x)^{\frac {n+1}{2}} \int \frac {\left (1-\cos ^2(e+f x)\right )^{\frac {1}{2} (-n-1)}}{a^2-b^2+b^2 \cos ^2(e+f x)}d\cos (e+f x)}{f}\right )}{d}\) |
\(\Big \downarrow \) 333 |
\(\displaystyle \frac {\sin ^{n+1}(e+f x) (d \csc (e+f x))^{n+1} \left (\frac {b \cos (e+f x) \sin ^{-n}(e+f x) \sin ^2(e+f x)^{n/2} \operatorname {AppellF1}\left (\frac {1}{2},\frac {n}{2},1,\frac {3}{2},\cos ^2(e+f x),-\frac {b^2 \cos ^2(e+f x)}{a^2-b^2}\right )}{f \left (a^2-b^2\right )}-\frac {a \cos (e+f x) \sin ^{-n-1}(e+f x) \sin ^2(e+f x)^{\frac {n+1}{2}} \operatorname {AppellF1}\left (\frac {1}{2},\frac {n+1}{2},1,\frac {3}{2},\cos ^2(e+f x),-\frac {b^2 \cos ^2(e+f x)}{a^2-b^2}\right )}{f \left (a^2-b^2\right )}\right )}{d}\) |
((d*Csc[e + f*x])^(1 + n)*Sin[e + f*x]^(1 + n)*((b*AppellF1[1/2, n/2, 1, 3 /2, Cos[e + f*x]^2, -((b^2*Cos[e + f*x]^2)/(a^2 - b^2))]*Cos[e + f*x]*(Sin [e + f*x]^2)^(n/2))/((a^2 - b^2)*f*Sin[e + f*x]^n) - (a*AppellF1[1/2, (1 + n)/2, 1, 3/2, Cos[e + f*x]^2, -((b^2*Cos[e + f*x]^2)/(a^2 - b^2))]*Cos[e + f*x]*Sin[e + f*x]^(-1 - n)*(Sin[e + f*x]^2)^((1 + n)/2))/((a^2 - b^2)*f) ))/d
3.9.28.3.1 Defintions of rubi rules used
Int[((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2)^(q_), x_Symbol] :> Sim p[a^p*c^q*x*AppellF1[1/2, -p, -q, 3/2, (-b)*(x^2/a), (-d)*(x^2/c)], x] /; F reeQ[{a, b, c, d, p, q}, x] && NeQ[b*c - a*d, 0] && (IntegerQ[p] || GtQ[a, 0]) && (IntegerQ[q] || GtQ[c, 0])
Int[((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.)/((a_) + (b_.)*sin[(e_.) + (f_.)*( x_)]), x_Symbol] :> Simp[a Int[(d*Sin[e + f*x])^n/(a^2 - b^2*Sin[e + f*x] ^2), x], x] - Simp[b/d Int[(d*Sin[e + f*x])^(n + 1)/(a^2 - b^2*Sin[e + f* x]^2), x], x] /; FreeQ[{a, b, d, e, f, n}, x] && NeQ[a^2 - b^2, 0]
Int[((d_.)*sin[(e_.) + (f_.)*(x_)])^(m_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x _)]^2)^(p_.), x_Symbol] :> With[{ff = FreeFactors[Cos[e + f*x], x]}, Simp[( -ff)*d^(2*IntPart[(m - 1)/2] + 1)*((d*Sin[e + f*x])^(2*FracPart[(m - 1)/2]) /(f*(Sin[e + f*x]^2)^FracPart[(m - 1)/2])) Subst[Int[(1 - ff^2*x^2)^((m - 1)/2)*(a + b - b*ff^2*x^2)^p, x], x, Cos[e + f*x]/ff], x]] /; FreeQ[{a, b, d, e, f, m, p}, x] && !IntegerQ[m]
Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(m_)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x _)]^(n_.))^(p_.), x_Symbol] :> Simp[d^(n*p) Int[(d*Csc[e + f*x])^(m - n*p )*(b + a*Csc[e + f*x]^n)^p, x], x] /; FreeQ[{a, b, d, e, f, m, n, p}, x] && !IntegerQ[m] && IntegersQ[n, p]
Int[(csc[(e_.) + (f_.)*(x_)]*(d_.))^(n_.)*(csc[(e_.) + (f_.)*(x_)]*(b_.) + (a_))^(m_.), x_Symbol] :> Simp[Sin[e + f*x]^n*(d*Csc[e + f*x])^n Int[(b + a*Sin[e + f*x])^m/Sin[e + f*x]^(m + n), x], x] /; FreeQ[{a, b, d, e, f, n} , x] && NeQ[a^2 - b^2, 0] && IntegerQ[m]
\[\int \frac {\left (d \csc \left (f x +e \right )\right )^{n}}{a +b \sin \left (f x +e \right )}d x\]
\[ \int \frac {(d \csc (e+f x))^n}{3+b \sin (e+f x)} \, dx=\int { \frac {\left (d \csc \left (f x + e\right )\right )^{n}}{b \sin \left (f x + e\right ) + a} \,d x } \]
\[ \int \frac {(d \csc (e+f x))^n}{3+b \sin (e+f x)} \, dx=\int \frac {\left (d \csc {\left (e + f x \right )}\right )^{n}}{a + b \sin {\left (e + f x \right )}}\, dx \]
\[ \int \frac {(d \csc (e+f x))^n}{3+b \sin (e+f x)} \, dx=\int { \frac {\left (d \csc \left (f x + e\right )\right )^{n}}{b \sin \left (f x + e\right ) + a} \,d x } \]
\[ \int \frac {(d \csc (e+f x))^n}{3+b \sin (e+f x)} \, dx=\int { \frac {\left (d \csc \left (f x + e\right )\right )^{n}}{b \sin \left (f x + e\right ) + a} \,d x } \]
Timed out. \[ \int \frac {(d \csc (e+f x))^n}{3+b \sin (e+f x)} \, dx=\int \frac {{\left (\frac {d}{\sin \left (e+f\,x\right )}\right )}^n}{a+b\,\sin \left (e+f\,x\right )} \,d x \]